Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Managerclient as submodule #4010

Merged
merged 12 commits into from
Sep 3, 2024
Merged

Conversation

karol-kokoszka
Copy link
Collaborator

@karol-kokoszka karol-kokoszka commented Aug 30, 2024

Fixes #4012

The goal is to extract managerclient as a separate submodule, so that it can be imported to other projects simply as

go get github.com/scylladb/scylla-manager/v3/pkg/managerclient

instead of importing full scylla-manager as dependency.
Doing the above is difficult if the repository uses google cloud SKD as a dependency, as our inhouse rclone (dependency to sm) uses replace directive on that lib to our inhouse google SDK....

Managerclient is intended to be used by Scylla Cloud.

Note:
Modules are named with v3/ prefix, to keep the backward compatibility with the imports.
v3/ prefix is added to the new path, as it must match the module name.


Please make sure that:

  • Code is split to commits that address a single change
  • Commit messages are informative
  • Commit titles have module prefix
  • Commit titles have issue nr. suffix

@karol-kokoszka karol-kokoszka force-pushed the managerclient-as-submodule branch 6 times, most recently from a6e9fa5 to 6d1a719 Compare August 30, 2024 15:16
Version and hearbeat endpoints are creating unnecessary dependencies in util pkg.
Service errors creates unnecessary dependencies in util
It removes unnecessary dependencies. By removing these dependencies it will be possible to create
submodules for utils and managerclient.
@karol-kokoszka karol-kokoszka force-pushed the managerclient-as-submodule branch 4 times, most recently from 4c625f4 to 4adcb5c Compare September 2, 2024 08:44
This commit extracts v3/pkg/util to explicit submodule, so that these utils are
easily shared between main scylla-manager module and managerclient submodule.
It's of preparation for substracting managerclient to separate submodule.
…ent as submodule

...so that it can be imported to other project as go get github.com/scylladb/scylla-manager/v3/pkg/managerclient
@karol-kokoszka karol-kokoszka marked this pull request as ready for review September 2, 2024 13:40
@Michal-Leszczynski
Copy link
Collaborator

@karol-kokoszka I understand that we want to wait for https://github.com/scylladb/siren/pull/11958 in order to validate correctness of this PR?

@karol-kokoszka
Copy link
Collaborator Author

@karol-kokoszka I understand that we want to wait for https://github.com/scylladb/siren/pull/11958 in order to validate correctness of this PR?

Yes, I want to import dependency to siren first and validate it.
I see that some enums are missing like types of tasks etc. But I would prefer to address it in other PR by extending the swagger definition.

@karol-kokoszka
Copy link
Collaborator Author

Siren builds properly when the managerclient submodule is used as dependency only.
I started stable e2e suite to verify it bit deeper.

Anyway, wants to merge it after the 3.3.2 patch fix.
The current PR is not gonna be included into this quick 3.3.2 fixing backups for 1 node clusters.

@karol-kokoszka
Copy link
Collaborator Author

Copy link
Collaborator

@Michal-Leszczynski Michal-Leszczynski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@karol-kokoszka karol-kokoszka merged commit 89f4cc5 into master Sep 3, 2024
51 checks passed
@karol-kokoszka karol-kokoszka deleted the managerclient-as-submodule branch September 3, 2024 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Extract managerclient to separate submodule
2 participants